package LeetcodeTest_thirty_five;

public class arrangeCoins
{
    public static void main(String[] args)
    {
        System.out.println(solution.arrangeCoins(1804289383));
    }
}
class solution {
    public static int arrangeCoins(int n)
    {
        long i=0;
        for(i=0;i<n;i++)
            if(((i+1)*(i+2))/2>n)
                break;
        return (int)i;
    }
}